package com.wyw.mybatis.plus.learning.controller;

import com.wyw.mybatis.plus.learning.base.PagedGridResult;
import com.wyw.mybatis.plus.learning.service.DataDictionaryService;
import lombok.extern.slf4j.Slf4j;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RequestParam;
import org.springframework.web.bind.annotation.RestController;

/**
 * @Title
 * @Description
 * @Author Mr Wu yewen.wu.china@gmail.com
 * @Date 2023/5/30 11:05
 * Update History:
 * Author        Time            Content
 */
@RestController
@RequestMapping("test")
@Slf4j
public class TestController {

    @Autowired
    private DataDictionaryService dataDictionaryService;

    /**
     *
     * @param page
     * @param limit
     */
    @GetMapping("page")
    public void testPage(@RequestParam Integer page, @RequestParam Integer limit) {
        PagedGridResult list = dataDictionaryService.getList(true, page, limit);
        log.info("{}", list);
    }
}
